-
Notifications
You must be signed in to change notification settings - Fork 81
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: Fix SDK version metadata in UserAgent header #1775
Conversation
…on.txt as well, and use that to initialize user agent middleware during runtime.
if (repoType == .awsSdkSwift) { | ||
try "\(newVersion)".write( | ||
toFile: "Sources/Core/AWSClientRuntime/Sources/AWSClientRuntime/Resources/sdk-version.txt", | ||
atomically: true, | ||
encoding: .utf8 | ||
) | ||
log("Updated AWSClientRuntime/Resources/Package.version: \(newVersion)") | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Non-Blocking: This may be the best solution but it gives me pause that we will be storing a duplicate of package.version
in a sdk-version.txt
. I understand the reasons for doing so but I wonder if there is either a better way or an opportunity for refactoring so that we only have a single file with the version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't want to mix auto-generated files into AWSClientRuntime
. That complicates our build/release pipeline.
I thought we had discussed using the contents of Package.version.next
to write the version string into the client during codegen. Did that approach not work?
@jbelkins |
Work taken over by @jbelkins. Closing PR after offline discussion. |
Issue #
1729
Description of changes
AWSClientRuntime/Resources/sdk-version.txt
as well, and use that to initialize user agent middleware during runtime similar to how partitions data is loaded.New/existing dependencies impact assessment, if applicable
Conventional Commits
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.